//
//  Person.h
//  OC作业
//
//  Created by dllo on 15/12/8.
//  Copyright © 2015年 dllo. All rights reserved.
//

#import <Foundation/Foundation.h>

@interface Person : NSObject



@property (nonatomic, retain) NSString *name;
@property (nonatomic, assign) NSInteger age;
@property (nonatomic, retain) NSString *sex;

- (instancetype)initWithName:(NSString *)name
                         age:(NSInteger)age
                         sex:(NSString *)sex;


//年龄升序
- (NSComparisonResult)compareWithAgeUP:(Person *) anotherPerson;
//姓名降序
- (NSComparisonResult)compareWithNameDown:(Person *)anotherPerson;
//性别升序
- (NSComparisonResult)compareWithSexUP:(Person *)anotherPerson;

@end
